<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ page import="com.dein.user.model.User" %>
<%@ page import="java.text.SimpleDateFormat" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
String userName = (String)request.getSession().getAttribute("userName");
Long userId = (Long)request.getSession().getAttribute("userId");
User user = (User) request.getSession().getAttribute("user");
SimpleDateFormat sdf=new SimpleDateFormat("yyyy/MM/dd");
String sex = null;
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>个人主页</title>
    <!-- icon图标-->
    <link rel="shortcut icon" href="images/deinIcon.ico" type="image/x-icon">
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
	<link rel="stylesheet" type="text/css" href="css/base.css">
	<link rel="stylesheet" type="text/css" href="css/pages/users.css">
	<link rel="stylesheet" type="text/css" href="css/icon/foundation-icons.css">
	

  </head>
  
  <body>
<div id='page'>
  <input id="userId" value="<%=userId%>" type="hidden">
  <div id="up"></div>
  <div id="headPortrait">
  	<div><img src="images/portrait.jpg"> &nbsp;&nbsp;&nbsp;<span><%= userName %></span>
   
    </div>
  </div>
  <div id="content">
  	<div id="left">
  		<div>
  		<h3> &nbsp;我的</h3><br><br>
 		<div class="fi-heart userInfo" id="musicPre">&nbsp;&nbsp;红心音乐</div><hr>
 		<div class='fi-trash userInfo' id="musicDis">&nbsp;&nbsp;垃圾桶音乐</div><hr>
		<div class='fi-align-center userInfo' id="musicAcc">&nbsp;&nbsp;累积收听</div><hr>
 		<div class='fi-clipboard-notes userInfo' id='myInfo'>&nbsp;&nbsp;个人资料</div>
 		</div>
   </div>
   <div id="right">
    <div id='user-info'>
    	<div class='header'>
   			<p>基本设置 </p>
   		</div>
   		<div class='info'>
   			 <ul class="profile_info">
       			 <li class="title">用户名：</li>
        		 <li class="detail"><%=user.getUserName()%></li>
    		</ul>
    		<ul class="profile_info">
        		<li class="title">密码：</li>
        		<li class="detail">
            		<a id='modify'>更改</a>
        		</li>
    		</ul>
   			 <ul class="profile_info">
        		<li class="title">邮箱：</li>
       			 <li class="detail">
                     <%=user.getEmail()%>
       			 </li>
    		</ul>
   		    <ul class="profile_info">
   				 <li class="title">性别：</li>
       			 <li class="detail"><%=sex = (user.getSex()=='f'?"女":"男")%></li>
    		</ul>
    		<ul class="profile_info">
   				 <li class="title">生日：</li>
       			 <li class="detail"><%=sdf.format(user.getBirthday())%></li>
    		</ul>
    	</div>
    </div>
    <div id='pw_modify'>
    	<div class='header'>
    	<p>修改我的登录密码</p>
    	</div>
    	<div class='info'>
    		
    		<ul class="profile_info">
   				 <li class="title">新密码：</li>
       			 <li class="detail"><input id="newPw" type='password'/></li>
    		</ul>
    		<ul class="profile_info">
   				 <li class="title">重复密码：</li>
       			 <li class="detail"><input id="validPw" type='password'/></li>
    		</ul>
    		<input id="submit" type='button' value='提 交'/>
        </div>
    </div>
   	<div id='record_viewer' >
   		<div class='header'>
   			<p>歌 曲 </p>
   			<span> 状 态</span>
   		</div>
   		<div id='info-music'>
   		  <div class='info-wrapper'>
   			<div class='song_info'>
   			    <img src='images/cover.jpg' >
   				<div class="props">
   			    <p class="song_title">そばにいるね</p><br>
   			    <p class="performer">SoulJa / 青山テルマ</p>
   		       </div>
   		    </div>
   		    <div class='action'>
   		        <div class='fi-music'></div>
   		        <div class='fi-x'></div>
   		    </div>
   	     </div>
      </div>
    </div>  
    </div>
   <!-- <div id='info'></div>  --> 
   
  </div>

  <!-- <div id='footer'>
 	</div> -->
  </div>
  <a id="backTop" href="javascript:;" data-title="返回顶部">
      <div class="btn-inner-text"></div>
  </a>
    <script type="text/javascript" src="js/frame/jquery-1.6.4.min.js"></script>
    <script type="text/javascript" src="js/users.js"></script>
  </body>
</html>
